/****************************************************************************
@file:test-util.cpp 
@author:ebayboy@163.com 
@date:2020-08-20 16:22 
@version: 1.0  
@description: cpp file 
@Copyright (c)  all right reserved 
**************************************************************************/

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>

#include <gtest/gtest.h>

#include <glog/logging.h>

using namespace std;

TEST(testCase, test0)
{
	//1. init with program name argv[0]
	google::InitGoogleLogging("glogtest");

	//2. set log dir
	FLAGS_log_dir = "/var/log/glog/";

	//3. output log
	LOG(INFO) << "info test";
	LOG(WARNING) << "warning test"; 
	LOG(ERROR) << "error test"; 

	//LOG(FATAL) << "fatal test";  //fatal will proc exit 

	//4. close && free memory
	google::ShutdownGoogleLogging();
}


